import router from '@/router'
import { httpSever } from './index'
import type { HomeCateItem, ListItem } from "@/types/Home"



export const getCategoryTopAPI = () => {
    return httpSever<HomeCateItem[]>({
        method: 'GET',
        url: '/lzl/getcate',
    })
}

export const getlunboAPI = () => {
    return httpSever({
        method: 'get',
        url: '/lzl/getlunbo'
    })
}

// export const getListAPI = () => {
//     return httpSever<ListItem[]>({
//         method: 'GET',
//         url: '/lzl/getlist',
//     })
// }

export const getUser = () => {
    return httpSever({
        method: 'get',
        url: '/lzl/getuser'
    })
}

export const shenhe = (data: any, file: any) => {
    return httpSever({
        method: 'post',
        url: '/lzl/shen',
        data: {
            url: data.Location,
            file: file.name
        }
    })
} 